package com.caiyi.financial.nirvana.sms.mapper;

import com.caiyi.financial.nirvana.sms.base.mapper.BaseMapper;
import com.caiyi.financial.nirvana.sms.entity.SmsUser;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.annotations.Select;
import org.apache.ibatis.annotations.Update;

/**
 * Created by Mario on 2017/12/15 0015.
 * SMS客户Mapper
 */
@Mapper
public interface SmsUserMapper extends BaseMapper<SmsUser> {

    @Select("select * from sms_user where account=#{account}")
    SmsUser getSmsUser(@Param("account") String account);

    @Update("update sms_user set password = #{password} where account = #{account}")
    int resetPwd(@Param("account") String account, @Param("password") String password);
}
